package com.bf.electroplating.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.bf.electroplating.mapper.ParkOutletMonitoringLogMapper;
import com.bf.electroplating.pojo.dto.frontPage.RainFallOutletHisDataDTO;
import com.bf.electroplating.pojo.entity.ParkOutletMonitoringLog;
import com.bf.electroplating.pojo.vo.home.EnterpriseOutletVO;
import com.bf.electroplating.service.IParkOutletMonitoringLogService;
import jakarta.annotation.Resource;
import org.springframework.stereotype.Service;

@Service
public class ParkOutletMonitoringLogServiceImpl extends ServiceImpl<ParkOutletMonitoringLogMapper, ParkOutletMonitoringLog>
        implements IParkOutletMonitoringLogService {
    @Resource
    private ParkOutletMonitoringLogMapper parkOutletMonitoringLogMapper;
    
    @Override
    public Page<EnterpriseOutletVO> enterpriseOutletSummaryVO(Page<Object> objectPage, RainFallOutletHisDataDTO dto) {
        // 创建新的分页对象
        Page<EnterpriseOutletVO> page = new Page<>(objectPage.getCurrent(), objectPage.getSize());
        
        // 调用Mapper方法获取分页数据
        return parkOutletMonitoringLogMapper.getEnterpriseOutletSummaryData(page, dto);
    }
}
